{% extends "base.html" %}


{% block headtitle %}Trips Confirmation{% endblock %}
{% block pagetitle %}Trips Confirmation{% endblock %}

{% block content %}
<h2>
Step 3. Pay for your trip(s).  
</h2>

<p>
Before submitting your payment, using the link below, please download, print, and sign the ski trip waiver form. Either mail the waiver to the address indicated on the form or bring it with you on the trip.  <a href="{{ waiver_url }}">Nisei Ski Club Weekend Ski Trip Waiver Form</a>
</p>

<table class="triplist">
  {% for trip in trips %}
  <tr class="{% if trip.trip_number|divisibleby:2 %}even{% else %}odd{% endif %}">
      <td>Trip #{{ trip.trip_number }}</td>
      <td>{{ trip.description }}</td>
      <td>{{ trip.start_date }}</td>
      <td>{{ trip.end_date }}</td>
      <td>{% if trip.is_member_only %}<b>member price</b>{% endif %}</td>
      <td>$ {{ trip.price|floatformat:2 }}</td>
  </tr>
  {% endfor %}
  {% if has_discount %}
  <tr>
      <td colspan="5" style="text-align: right">Discount:</td>
      <td>$ {{ discount|floatformat:2  }}</td>
  </tr>
  {% endif %}
  <tr>
      <td colspan="5" style="text-align: right"><b>Total:</b></td>
      <td><b>$ {{ total_cost|floatformat:2 }}</b></td>
  </tr>
</table>


{% ifequal "paypal" trip_order.pay_method %}

<p>Please click the button to pay for your trip(s). You will be taken to PayPal where you can use a credit card or a PayPal account to make your payment.</p>

<form action="https://www.paypal.com/cgi-bin/webscr" method="post">  
 <input type="hidden" name="cmd" value="_xclick">  
 <INPUT TYPE="hidden" NAME="currency_code" value="USD">
 <INPUT TYPE="hidden" NAME="no_shipping" value="1">
 <input type="hidden" name="business" value="VESAM3853HAFQ">
 <input type="hidden" name="item_name" value="{{ trips_desc }}">  
 <input type="hidden" name="item_number" value="{{ trip_order.key.id  }}">  
 <input type="hidden" name="amount" value="{{ trip_order.total }}">  
 <input type="hidden" name="first_name" value="{{ trip_order.billing_first_name }}">  
 <input type="hidden" name="last_name" value="{{ trip_order.billing_last_name }}">  
 <input type="hidden" name="email" value="{{ trip_order.billing_email }}">  
 <input type="image" name="submit" border="0" src="https://www.paypal.com/en_US/i/btn/btn_buynowCC_LG.gif" alt="PayPal - The safer, easier way to pay online">  
</form>

{% else %}

<p style="font-weight: bold">
Please print this page and mail your check for the amount listed above to:
</p>

<div style="margin: 1em;">
    {{ address.line1 }}<br/>
    {{ address.line2 }}<br/>
    {{ address.street }}<br/>
    {{ address.city }}, {{ address.state }}  {{address.zip}}
</div>

{% endifequal %}

<p style="padding-top: 1em; margin-top: 2em; border-top: 1px dashed black;">Below is your sign up information.</p>

<form action="" method="POST" class="signup">
<table class="form">
{% for field in form %}
  <tr>
    <th>{{ field.label }}</th>
    <td>{{ field.data }}<td>
  </tr>
{% endfor %}
</table>

</form>


 
{% endblock %}
